Underlined headers

The preamble command \underhead places a rule of length \textwidth a distance of \underheadsep under the header text. The value of \underheadsep can be changed in the preamble by \settolength. This length is added to the style parameter \headhight, so that the top of the text is moved down by \underheadsep. To keep the top of the text in the original position execute the command \addtolength{\headsep}{-\underheadsep}.

In preparing assignments and classroom notes, I find it convenient to use the header line as a title, in which case I do not want it underlined on the first page. Underlining on the current page can be suppressed by the command \nounderhead.